<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title></title>
		
		<script type="text/javascript">
			
			var arr=[1,5,8,2,4,6,8];
			
			arr.sort(function(a,b){
				return a-b;
			})
			
			console.log(arr);
		</script>
	</head>
	<body>
	</body>
</html>
